package com.liuqi.loggers.core.converters;

import com.liuqi.loggers.core.Converter;
import com.liuqi.loggers.core.LoggerEvent;

/**
 * return the {@link #literal}
 *
 * @author liuqi
 * @date 2024/11/5 16:54
 **/
public class LiteralConverter implements Converter {

    private final String literal;

    public LiteralConverter(String literal) {
        this.literal = literal;
    }

    @Override
    public String convert(LoggerEvent loggerEvent) {
        return literal;
    }

    @Override
    public String convert0(LoggerEvent event) {
        return literal;
    }

    @Override
    public String name() {
        return null;
    }

}
